package com.itheima.自习.第一次.第十九题;

//定义狗类继承动物类，行为：eat(String something)方法,看家lookHome方法(无参数)
public class Dog extends Animal{
    public Dog() {
    }

    public Dog(int age, String color) {
        super(age, color);
    }

    @Override
    public void eat(String something) {
        System.out.println(this.getAge() + "岁的" + this.getColor() + "颜色的狗两只前腿死死的抱住"+ something+ "猛吃");
    }

    public void lookHome(){
        System.out.println("看家");
    }
}
